package cn.jetpiece.cloud.joss.app.config;

import cn.jetpiece.cloud.joss.app.core.metadata.OssMetaObjectHandler;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.transaction.annotation.EnableTransactionManagement;

/**
 * @author XuJZ
 * @since 2020/9/5
 */
@Configuration
@EnableTransactionManagement(proxyTargetClass = true)
@MapperScan(basePackages = {"cn.jetpiece.cloud.**.mapper"})
public class DataSourceConfig {

    /**
     * 自定义公共字段自动注入
     */
    @Bean
    public OssMetaObjectHandler metaObjectHandler() {
        return new OssMetaObjectHandler();
    }
}
